Back to the Vavoom Forum Archives
Crimson Wizard
Crimson Wizard
Crimson Wizard
SpeechNum = GetSpeech();
if (SpeechNum)
{
<...>
DropItemType = LineSpecialLevelInfo(Level).GetClassFromID(Speech->DropItem);
if (DropItemType)
{
DropItem(DropItemType, 0, 1.0);
return;
}
}
If Speech->DropItem == 0, then GetClassFromID method selects first found class with ConversationID == 0, and usually it is StrifePlayer class. Basically just a player pawn is dropped, not linked to any real player. Speech->DropItem can be checked, and if it is equal to 0, it should be ignored.
On the other hand, this could be fixed also by making LineSpecialLevelInfo::GetClassFromID() function return 'none' for ID == 0. I believe it will be even better solution, because GetClassFromID is called from other places as well.
It can be done like this:
final class<EntityEx> GetClassFromID(int ID)
{
class Cls;
if (!ID)
{
return none;
}
<...>
Firebrand
Firebrand